package com.example.mealplanner;

import java.util.ArrayList;
import java.util.List;

import android.os.Bundle;
import android.app.Activity;
import android.view.Menu;
import android.widget.ArrayAdapter;
import android.widget.ListView;

public class WaitingListActivity extends Activity {

	private ListView waitingItemList;
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_waiting_list);
		
		waitingItemList = (ListView) findViewById(R.id.waiting_list);
		
		List<String> waitingList = new ArrayList<String>();
		waitingList.add("Pizza Hut");
		waitingList.add("Cafe de Coral");
		waitingList.add("Won ton noodles");
		
	    //final ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
	    //        android.R.layout.simple_expandable_list_item_1, waitingList);
	    final ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
	            android.R.layout.simple_list_item_1, waitingList);
	    waitingItemList.setAdapter(adapter);
	}

	@Override
	public boolean onCreateOptionsMenu(Menu menu) {
		// Inflate the menu; this adds items to the action bar if it is present.
		getMenuInflater().inflate(R.menu.waiting_list, menu);
		return true;
	}

}
